package com.jc.subject.common.enums;

/**
 * @Description: 分类类型枚举
 * @Author: ASL_ly
 * @Package: com.jc.subject.common.enums
 * @Project: jc-club
 * @Date: 2024/10/22  21:24
 */
public enum CategoryTypeEnum {
    PRIMARY(1, "岗位大类"),
    SECOND(2, "二级分类");

    public Integer code;
    public String desc;

    CategoryTypeEnum(Integer code, String desc) {
        this.code = code;
        this.desc = desc;
    }

    public static SubjectInfoTypeEnum getByCode(Integer codeVal){
        for(SubjectInfoTypeEnum resultCodeEnum : SubjectInfoTypeEnum.values()){
            if(resultCodeEnum.code == codeVal){
                return resultCodeEnum;
            }
        }
        return null;
    }
}
